import request from "../../../../../../assets/js/request";

/**
 * 获取房源数据
 * @param houseSearch
 * @returns {*}
 */
export function getHouseData(houseSearch){
  return request({
    url: "/house/inspectionSearch",
    method: "POST",
    data: houseSearch,
    headers:{
      "Content-Type" : "application/json"
    }
  })
}

/**
 * 获取巡查员数据
 * @param inspectorSearch
 * @returns {*}
 */
export function getInspectorData(inspectorSearch){
  return request({
    url: "/managerUser/getInspector",
    method: "POST",
    data: inspectorSearch,
    headers:{
      "Content-Type" : "application/json"
    }
  })
}

/**
 * 添加派遣督查
 * @param muuid
 * @param huuid
 * @param inspectionTime
 * @returns {Promise<AxiosResponse<any>> | *}
 */
export function editInspection(inspection){
  return request({
    url: "/inspection/editInspection",
    method: 'post',
    data: inspection,
    headers: {
      "Content-Type" : "application/json"
    }
  })
}
